<?php

$array;
for ($i = 0; $i < 10; $i++) {
    $array[$i] = $i;
}

$array = array_reverse($array);

foreach ($array as $value) {
    echo "[$value] ";
}
?>
